#include <iostream>
using namespace std;

class Point
{
private:
    int x;
    int y;
public:
    Point(int x,int y)
    :x(x),
    y(y)
    {
    }
    ~Point(){}
    void setX(int x)
    {
        this->x = x;
    }
    int getX() const
    {
        return this->x;
    }
    void setY(int y)
    {
        this->y = y;
    }
    int getY() const
    {
        return this->y;
    }
    void display() const
    {
        cout<<"("<<this->x<<","<<this->y<<")"<<endl;
    }
};

//实现两点间的相加
Point addPoint(const Point& lhs,const Point& rhs)
{
    int x=lhs.getX()+rhs.getX();
    int y=lhs.getY()+rhs.getY();

    Point p(x,y);
    return p;
}
//实现两点间的相加2
const Point operator + (const Point& lhs,const Point& rhs)
{
    int x=lhs.getX()+rhs.getX();
    int y=lhs.getY()+rhs.getY();

    Point p(x,y);
    return p;
}